package me.thinkjet.sso.server.service;

import com.jfinal.plugin.activerecord.Model;

/**
 * 
 * @ClassName UserService
 * @author johnny_zyc
 * @Modified 2013-3-2 下午2:47:53
 * 
 */
@SuppressWarnings({ "rawtypes" })
public interface UserService<M extends Model> {

	public final static String PASSWORD_FILED_NAME = "password";
	public final static String USER_ENABLE_FILED_NAME = "enable";

	public M getUser(String loginName);

	public String getEncodedPassword(String password);

	public void createUser(M user);

	public void modifyself(M user);

	public M findUserByUsername(String username);

	public void resetPassword(M user);

	public M findUserByEmail(String email);

	public M findUserByUId(Long uid);
}
